<script src="../../routers/admin.js"></script>
<link rel="stylesheet" href="../../public/style/css/main.css">
<script src="../../routers/main.js"></script>{% extends 'layout.html'%}
{% block title%}用户列表{%endblock%}
{%block scripts%} {%endblock%}
{% block body%}


<table class="table table-hover table-striped">
    <tr>
        <td>Id</td>
        <td>分类</td>
        <td>标题</td>
        <td>作者</td>
        <td>简介</td>
        <td>最近修改时间</td>
        <td>阅读量</td>
        <td>操作</td>
    </tr>
    {% for label in blogs %}
    <tr>
        <td>{{label._id.toString()}}</td>
        <td>{{label.category}}</td>
        <td>{{label.title}}</td>
        <td>{{label.author}}</td>
        <td>{{label.synopsis}}</td>
        <td>{{label.created|date('Y-m-d H:i',8*-60)}}</td>
        <td>{{label.reading}}</td>
        <td>
            <a href="/admin/blog/change?id={{label._id.toString()}}">编辑</a>||
            <a href="/admin/blog/delete?id={{label._id.toString()}}" >删除</a>||
            <a href="/admin/blog/detail?id={{label._id.toString()}}" >查看</a>||
        </td>
    </tr>
    {% endfor%}
</table>
<nav aria-label="...">
    <ul class="pager">
        <li><a href="/admin/blog?page={{page-1}}">上一页</a></li>
        {{page}}/{{maxPage}}
        <li><a href="/admin/blog?page={{page+1}}">下一页</a></li>
    </ul>
</nav>

{% endblock%}